import request from "@/utils/request";

//获取轮播图
export function getBanner() {
  return request({
    url: "/home/carousel/list",
    method: "get",
  });
}

export function getMenuList(id) {
  return request({
    url: "/home/menu/list?orderByColumn=" + id,
    method: "get",
  });
}
//新增留言
export function addByStudent(data) {
  return request({
    url: "/artificial/message/addByStudent",
    method: "get",
    params: data,
  });
}

//
export function getByStudent(data) {
  return request({
    url: "/artificial/message/getByStudent",
    method: "get",
    params: data,
  });
}

export function getMineInfo() {
  return request({
    url: "/wechat/user/info",
    method: "get",
  });
}

export function article(data) {
  return request({
    url: "/article/article/list",
    method: "get",
    params: data,
  });
}

export function articleDetail(id) {
  return request({
    url: `/article/article/${id}`,
    method: "get",
  });
}

export function incubationDetail(id) {
  return request({
    url: `/article/incubation/${id}`,
    method: "get",
  });
}

//   /article/incubation/list
export function incubationList(data) {
  return request({
    url: `/article/incubation/list`,
    method: "get",
    params: data,
  });
}

export function ai(data) {
  return request({
    url: `/AI/getMessage`,
    method: "get",
    params: data,
  });
}

export function listByStudent() {
  return request({
    url: `/record/volcano/listByStudent`,
    method: "get",
  });
}

export function infoEdit(data) {
  return request({
    url: `/wechat/user/edit`,
    method: "post",
    data: data,
  });
}

// /answer/papers/listByStudent

export function listTest(data) {
  return request({
    url: `/answer/papers/listByStudent`,
    method: "get",
    params: data,
  });
}

export function examDetail(data) {
  return request({
    url: `/answer/papers/infoByStudent`,
    method: "get",
    params: data,
  });
}

export function submitPaper(data) {
  return request({
    url: `/answer/papers/submitPaper`,
    method: "post",
    data: data,
  });
}

export function examDetails(data) {
  return request({
    url: `/answer/papers/examDetail`,
    method: "get",
    params: data,
  });
}

export function getCount() {
  return request({
    url: `/artificial/message/getCount`,
    method: "get",
  });
}

export function reply(data) {
  return request({
    url: `/artificial/reply`,
    method: "put",
    data:data
  });
}
// /answer/records/{id}
// export function examDetails(data) {
//   return request({
//     url: `/answer/papers/examDetail/${data}`,
//     method: "get",
//   });
// }
